package com.yoyo.itravel.service;

import com.yoyo.itravel.bean.SightTicketStock;
import com.yoyo.itravel.exceptions.SightStockException;

import java.util.List;

/**
 * @Description 景点门票库存操作服务层接口
 * @Author HZX
 * @Version 1.0
 * @Date 2020/6/23 21:13
 */
public interface ISightTicketStockService {

    /**
     * @Description 插入景点门票库存信息
     *
     * @Param sightStock
     * @Return boolean
     */
    boolean addSightStock(SightTicketStock sightStock) throws SightStockException;

    /**
     * @Description 通过景点门票库存id修改景点门票库存信息
     *
     * @Param sightStock
     * @Return boolean
     */
    boolean updateById(SightTicketStock sightStock) throws SightStockException;

    /**
     * @Description 通过景点门票库存id修改库存数量
     *
     * @param detailTypeId
     * @param nowStockNum
     * @return boolean
     */
    // boolean updateStockByDetailTypeId(String ticketStockId, Integer nowStockNum) throws SightStockException;

    /**
     * @Description 通过景点门票库存id删除景点门票库存信息
     *
     * @Param ticketStockId
     * @Return boolean
     */
    boolean deleteById(String ticketStockId) throws SightStockException;

    /**
     * @Description 根据条件得到对应的景点门票库存【可以用于：通过景点门票详细类型和出行日期获得所对应的景点库存数量】
     *
     * @Param sightStock
     * @Return Object
     */
    Object findByCondition(SightTicketStock sightStock) throws SightStockException;

    /**
     * @Description 根据条件得到对应的景点门票库存
     *
     * @Param ticketStockId
     * @Return com.yoyo.itravel.bean.SightStock
     */
    SightTicketStock findById(String ticketStockId) throws SightStockException;

    /**
     * @Description 获得所有的景点门票库存信息
     *
     * @Param
     * @Return java.util.List<com.yoyo.itravel.bean.SightStock>
     */
    List<SightTicketStock> findAll() throws SightStockException;

    /**
     * @Description
     *
     * @Param ticketTypeDetail
     * @Param tripDate
     * @Return java.lang.Integer
     */
    // Integer findNowStockNumByDetailTypeIdAndDate(TicketTypeDetail ticketTypeDetail, Date tripDate);
}
